Integrand size = 22, antiderivative size = 135 \[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\frac {a (e x)^{2 n}}{2 e n}+\frac {2 b x^{-n} (e x)^{2 n} \arctan \left (e^{c+d x^n}\right )}{d e n}-\frac {i b x^{-2 n} (e x)^{2 n} \operatorname {PolyLog}\left (2,-i e^{c+d x^n}\right )}{d^2 e n}+\frac {i b x^{-2 n} (e x)^{2 n} \operatorname {PolyLog}\left (2,i e^{c+d x^n}\right )}{d^2 e n} \]
1/2*a*(e*x)^(2*n)/e/n+2*b*(e*x)^(2*n)*arctan(exp(c+d*x^n))/d/e/n/(x^n)-I*b *(e*x)^(2*n)*polylog(2,-I*exp(c+d*x^n))/d^2/e/n/(x^(2*n))+I*b*(e*x)^(2*n)* polylog(2,I*exp(c+d*x^n))/d^2/e/n/(x^(2*n))
Time = 0.61 (sec) , antiderivative size = 260, normalized size of antiderivative = 1.93 \[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\frac {x^{-2 n} (e x)^{2 n} \left (a d^2 x^{2 n}+2 i b c \log \left (1-i e^{c+d x^n}\right )-b \pi \log \left (1-i e^{c+d x^n}\right )+2 i b d x^n \log \left (1-i e^{c+d x^n}\right )-2 i b c \log \left (1+i e^{c+d x^n}\right )+b \pi \log \left (1+i e^{c+d x^n}\right )-2 i b d x^n \log \left (1+i e^{c+d x^n}\right )-2 i b c \log \left (\cot \left (\frac {1}{4} \left (2 i c+\pi +2 i d x^n\right )\right )\right )+b \pi \log \left (\cot \left (\frac {1}{4} \left (2 i c+\pi +2 i d x^n\right )\right )\right )-2 i b \operatorname {PolyLog}\left (2,-i e^{c+d x^n}\right )+2 i b \operatorname {PolyLog}\left (2,i e^{c+d x^n}\right )\right )}{2 d^2 e n} \]
((e*x)^(2*n)*(a*d^2*x^(2*n) + (2*I)*b*c*Log[1 - I*E^(c + d*x^n)] - b*Pi*Lo g[1 - I*E^(c + d*x^n)] + (2*I)*b*d*x^n*Log[1 - I*E^(c + d*x^n)] - (2*I)*b* c*Log[1 + I*E^(c + d*x^n)] + b*Pi*Log[1 + I*E^(c + d*x^n)] - (2*I)*b*d*x^n *Log[1 + I*E^(c + d*x^n)] - (2*I)*b*c*Log[Cot[((2*I)*c + Pi + (2*I)*d*x^n) /4]] + b*Pi*Log[Cot[((2*I)*c + Pi + (2*I)*d*x^n)/4]] - (2*I)*b*PolyLog[2, (-I)*E^(c + d*x^n)] + (2*I)*b*PolyLog[2, I*E^(c + d*x^n)]))/(2*d^2*e*n*x^( 2*n))
Time = 0.31 (sec) , antiderivative size = 135, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {2010, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int (e x)^{2 n-1} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx\) |
\(\Big \downarrow \) 2010 |
\(\displaystyle \int \left (a (e x)^{2 n-1}+b (e x)^{2 n-1} \text {sech}\left (c+d x^n\right )\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {a (e x)^{2 n}}{2 e n}+\frac {2 b x^{-n} (e x)^{2 n} \arctan \left (e^{c+d x^n}\right )}{d e n}-\frac {i b x^{-2 n} (e x)^{2 n} \operatorname {PolyLog}\left (2,-i e^{d x^n+c}\right )}{d^2 e n}+\frac {i b x^{-2 n} (e x)^{2 n} \operatorname {PolyLog}\left (2,i e^{d x^n+c}\right )}{d^2 e n}\) |
(a*(e*x)^(2*n))/(2*e*n) + (2*b*(e*x)^(2*n)*ArcTan[E^(c + d*x^n)])/(d*e*n*x ^n) - (I*b*(e*x)^(2*n)*PolyLog[2, (-I)*E^(c + d*x^n)])/(d^2*e*n*x^(2*n)) + (I*b*(e*x)^(2*n)*PolyLog[2, I*E^(c + d*x^n)])/(d^2*e*n*x^(2*n))
3.1.74.3.1 Defintions of rubi rules used
Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x] , x] /; FreeQ[{c, m}, x] && SumQ[u] && !LinearQ[u, x] && !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 1.70 (sec) , antiderivative size = 368, normalized size of antiderivative = 2.73
method | result | size |
risch | \(\frac {a x \,{\mathrm e}^{\frac {\left (2 n -1\right ) \left (-i \operatorname {csgn}\left (i e \right ) \operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i e x \right ) \pi +i \operatorname {csgn}\left (i e \right ) \operatorname {csgn}\left (i e x \right )^{2} \pi +i \operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i e x \right )^{2} \pi -i \operatorname {csgn}\left (i e x \right )^{3} \pi +2 \ln \left (e \right )+2 \ln \left (x \right )\right )}{2}}}{2 n}+\frac {2 b \,{\mathrm e}^{-i \pi n \,\operatorname {csgn}\left (i e \right ) \operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i e x \right )} {\mathrm e}^{i \pi n \,\operatorname {csgn}\left (i e \right ) \operatorname {csgn}\left (i e x \right )^{2}} {\mathrm e}^{i \pi n \,\operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i e x \right )^{2}} {\mathrm e}^{-i \pi n \operatorname {csgn}\left (i e x \right )^{3}} {\mathrm e}^{\frac {i \operatorname {csgn}\left (i e \right ) \operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i e x \right ) \pi }{2}} {\mathrm e}^{-\frac {i \operatorname {csgn}\left (i e \right ) \operatorname {csgn}\left (i e x \right )^{2} \pi }{2}} {\mathrm e}^{-\frac {i \operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i e x \right )^{2} \pi }{2}} {\mathrm e}^{\frac {i \operatorname {csgn}\left (i e x \right )^{3} \pi }{2}} e^{2 n} {\mathrm e}^{c} \left (-\frac {\sqrt {-{\mathrm e}^{2 c}}\, x^{n} d \left (\ln \left (1+{\mathrm e}^{d \,x^{n}} \sqrt {-{\mathrm e}^{2 c}}\right )-\ln \left (1-{\mathrm e}^{d \,x^{n}} \sqrt {-{\mathrm e}^{2 c}}\right )\right ) {\mathrm e}^{-2 c}}{2}-\frac {\sqrt {-{\mathrm e}^{2 c}}\, \left (\operatorname {dilog}\left (1+{\mathrm e}^{d \,x^{n}} \sqrt {-{\mathrm e}^{2 c}}\right )-\operatorname {dilog}\left (1-{\mathrm e}^{d \,x^{n}} \sqrt {-{\mathrm e}^{2 c}}\right )\right ) {\mathrm e}^{-2 c}}{2}\right )}{e n \,d^{2}}\) | \(368\) |
1/2*a/n*x*exp(1/2*(2*n-1)*(-I*csgn(I*e)*csgn(I*x)*csgn(I*e*x)*Pi+I*csgn(I* e)*csgn(I*e*x)^2*Pi+I*csgn(I*x)*csgn(I*e*x)^2*Pi-I*csgn(I*e*x)^3*Pi+2*ln(e )+2*ln(x)))+2*b*exp(-I*Pi*n*csgn(I*e)*csgn(I*x)*csgn(I*e*x))*exp(I*Pi*n*cs gn(I*e)*csgn(I*e*x)^2)*exp(I*Pi*n*csgn(I*x)*csgn(I*e*x)^2)*exp(-I*Pi*n*csg n(I*e*x)^3)*exp(1/2*I*Pi*csgn(I*e)*csgn(I*x)*csgn(I*e*x))*exp(-1/2*I*Pi*cs gn(I*e)*csgn(I*e*x)^2)*exp(-1/2*I*Pi*csgn(I*x)*csgn(I*e*x)^2)*exp(1/2*I*Pi *csgn(I*e*x)^3)*(e^n)^2/e*exp(c)/n/d^2*(-1/2*(-exp(2*c))^(1/2)*x^n*d*(ln(1 +exp(d*x^n)*(-exp(2*c))^(1/2))-ln(1-exp(d*x^n)*(-exp(2*c))^(1/2)))*exp(-2* c)-1/2*(-exp(2*c))^(1/2)*(dilog(1+exp(d*x^n)*(-exp(2*c))^(1/2))-dilog(1-ex p(d*x^n)*(-exp(2*c))^(1/2)))*exp(-2*c))
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 664 vs. \(2 (124) = 248\).
Time = 0.28 (sec) , antiderivative size = 664, normalized size of antiderivative = 4.92 \[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\text {Too large to display} \]
1/2*(a*d^2*cosh((2*n - 1)*log(e))*cosh(n*log(x))^2 + a*d^2*cosh(n*log(x))^ 2*sinh((2*n - 1)*log(e)) + (a*d^2*cosh((2*n - 1)*log(e)) + a*d^2*sinh((2*n - 1)*log(e)))*sinh(n*log(x))^2 - 2*(-I*b*cosh((2*n - 1)*log(e)) - I*b*sin h((2*n - 1)*log(e)))*dilog(I*cosh(d*cosh(n*log(x)) + d*sinh(n*log(x)) + c) + I*sinh(d*cosh(n*log(x)) + d*sinh(n*log(x)) + c)) - 2*(I*b*cosh((2*n - 1 )*log(e)) + I*b*sinh((2*n - 1)*log(e)))*dilog(-I*cosh(d*cosh(n*log(x)) + d *sinh(n*log(x)) + c) - I*sinh(d*cosh(n*log(x)) + d*sinh(n*log(x)) + c)) - 2*(I*b*c*cosh((2*n - 1)*log(e)) + I*b*c*sinh((2*n - 1)*log(e)))*log(cosh(d *cosh(n*log(x)) + d*sinh(n*log(x)) + c) + sinh(d*cosh(n*log(x)) + d*sinh(n *log(x)) + c) + I) - 2*(-I*b*c*cosh((2*n - 1)*log(e)) - I*b*c*sinh((2*n - 1)*log(e)))*log(cosh(d*cosh(n*log(x)) + d*sinh(n*log(x)) + c) + sinh(d*cos h(n*log(x)) + d*sinh(n*log(x)) + c) - I) - 2*(I*b*d*cosh((2*n - 1)*log(e)) *cosh(n*log(x)) + I*b*c*cosh((2*n - 1)*log(e)) + (I*b*d*cosh(n*log(x)) + I *b*c)*sinh((2*n - 1)*log(e)) + (I*b*d*cosh((2*n - 1)*log(e)) + I*b*d*sinh( (2*n - 1)*log(e)))*sinh(n*log(x)))*log(I*cosh(d*cosh(n*log(x)) + d*sinh(n* log(x)) + c) + I*sinh(d*cosh(n*log(x)) + d*sinh(n*log(x)) + c) + 1) - 2*(- I*b*d*cosh((2*n - 1)*log(e))*cosh(n*log(x)) - I*b*c*cosh((2*n - 1)*log(e)) + (-I*b*d*cosh(n*log(x)) - I*b*c)*sinh((2*n - 1)*log(e)) + (-I*b*d*cosh(( 2*n - 1)*log(e)) - I*b*d*sinh((2*n - 1)*log(e)))*sinh(n*log(x)))*log(-I*co sh(d*cosh(n*log(x)) + d*sinh(n*log(x)) + c) - I*sinh(d*cosh(n*log(x)) +...
\[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\int \left (e x\right )^{2 n - 1} \left (a + b \operatorname {sech}{\left (c + d x^{n} \right )}\right )\, dx \]
\[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\int { {\left (b \operatorname {sech}\left (d x^{n} + c\right ) + a\right )} \left (e x\right )^{2 \, n - 1} \,d x } \]
2*b*integrate((e*x)^(2*n - 1)/(e^(d*x^n + c) + e^(-d*x^n - c)), x) + 1/2*( e*x)^(2*n)*a/(e*n)
\[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\int { {\left (b \operatorname {sech}\left (d x^{n} + c\right ) + a\right )} \left (e x\right )^{2 \, n - 1} \,d x } \]
Timed out. \[ \int (e x)^{-1+2 n} \left (a+b \text {sech}\left (c+d x^n\right )\right ) \, dx=\int \left (a+\frac {b}{\mathrm {cosh}\left (c+d\,x^n\right )}\right )\,{\left (e\,x\right )}^{2\,n-1} \,d x \]